from src.game.entity.bullet import EntityBullet
from src.game.entity.projectile import EntityProjectile
from src.game.entity.living import EntityLiving
from src.game.buff.speed import SpeedBuff

class EntityArrow(EntityBullet):
    
    name = "entityarrow"
    
    def __init__(self):
        EntityBullet.__init__(self)
        
    def onCollision(self, entity):
        EntityProjectile.onCollision(self, entity)
        if isinstance(entity, EntityLiving):
            entity.damage(1, EntityArrow.name, 2)
            entity.addBuff(SpeedBuff())
            
            